<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
<!DOCTYPE html>
<html lang="zh-CN">
  
  <head>
    
    <%@ include file="/WEB-INF/include/meta.jsp"%>
    <%@ include file="/WEB-INF/include/css.jsp"%>
    <link href="${ctx.resource}/css/goals.css" rel="stylesheet">
    
  </head>
  <!-- end header -->
  <body>
    <div class="page-group">
      <div class="page page-current">
        
        <header class="bar bar-nav fs-header-small">
          <a onclick="window.history.back();" class="icon icon-left pull-left"></a>
          <h1 class="title">课程${session}</h1>
        </header>
        
        <div class="content">
          <div class="list-block media-list no-margin">
            <ul>
              <li class="course">
                <div class="item-content">
                  <div class="item-media"><img src="${cloud.prod}/${courseSchedule.course.cover}-avatar" style='width: 4rem;'></div>
                  <div class="item-inner">
                    <div class="item-title-row">
                      <div class="item-title">${courseSchedule.course.name}</div>
                    </div>
                    <div class="item-subtitle" style="margin: .3rem 0 0 0;">门店：<span class="color-default">${courseSchedule.site.name}</span></div>
                    <div class="item-text">
                      教练：<span class="color-default">${courseSchedule.coach.name}</span><br>
                      时间：&nbsp;<span class="color-blue"><fmt:formatDate value="${courseSchedule.occurDate}" pattern="yyyy-MM-dd"/>&nbsp;&nbsp;${courseSchedule.occurHour}</span>
                    </div>
                  </div>
                </div>
              </li>
            </ul>
          </div>
          
          <c:if test="${not empty plannedSchedule}">
            <div style="background: white;padding: .25rem .75rem;margin: .75rem 0;">上课内容：
              <span class="pull-right">
                <c:forEach var="content" items="${plannedSchedule.contentList}" varStatus="status">
                  ${status.index eq 0 ? '' : '+'}${content.description}
                </c:forEach>
              </span>
            </div>
          </c:if>
          
          <c:if test="${not empty coursewares}">
            <div class="content-block course-target-course target-course" style="padding: 0; margin-top: 1rem">
              <div class="basic-item flex-box basic-header">
                <div class="item" style="width: 30%;flex: none;">动作</div>
                <div class="item" style="width: 10%;flex: none;">组数</div>
                <div class="item" style="width: 20%;flex: none;">每组次数</div>
                <div class="item" style="width: 20%;flex: none;">最大重量</div>
                <div class="item" style="width: 10%;flex: none;">计时</div>
                <div class="item" style="width: 10%;flex: none;"></div>
              </div>
              <c:forEach var="courseware" items="${coursewares}">
                <div class="basic-item flex-box">
                  <div class="item flex-shrink" style="width: 30%;flex: none;">${courseware.movement.name}</div>
                  <div class="item" style="width: 10%;flex: none;"><span class="big-size">${courseware.groupAmount}</span></div>
                  <div class="item" style="width: 20%;flex: none;"><span class="big-size">${courseware.movementNumber}</span></div>
                  <div class="item" style="width: 20%;flex: none;"><span class="big-size">${courseware.maxWeight}</span></div>
                  <div class="item" style="width: 10%;flex: none;"><span class="big-size">${courseware.time}</span></div>
                  <a class="item" style="width: 10%;flex: none;color: #929292" href="${ctx.host}/rounds/${courseSchedule.courseRound.id}/course-coursewares/${courseSchedule.id}/coursewares/${courseware.id}"><span class="icon icon-right"></span></a>
                </div>
              </c:forEach>
            </div>
          </c:if>
          <!-- <c:if test="${courseSchedule.scheduleStatus.finish}">
            <div class="coach-comment">
              <h1 style="font-size: .9rem;margin: .2rem">教练寄语：</h1>
              <p>间距间距军军军军军军军军军军军${courseSchedule.comment}</p>
            </div>
          </c:if> -->
        </div>
        <!-- End Content -->
      </div>
    </div>
  </body>
</html>